package com.itheima.a01mystream;

import java.util.ArrayList;
import java.util.Collections;

public class StreamDemo2 {
    public static void main(String[] args) {
        //创建单列集合 添加元素
        ArrayList<String> list =new ArrayList<>();
        //添加元素
        Collections.addAll(list,"a","b","c","d");
        list.stream().forEach(s-> System.out.println(s));

    }
}
